<?php
namespace app\home\model;

use think\Model;
use think\Db;

class Index extends Model
{
    public function index()
    {
        $data = Db::name('category c')
            ->field('c.category_name')
            ->where('is_active=1')
            ->select();

        return $data;

    }
}